package jml.defaultimple.util;

import java.util.ArrayList;
import java.util.Collections;
import java.util.Comparator;
import java.util.Enumeration;
import java.util.Hashtable;
import java.util.List;

public class UCollections
{
	public static <K,V> List<K> sortHashKeys(Hashtable<K, V> t, Comparator<K> c)
	{
		ArrayList<K> keys = new ArrayList<K>();
		for(Enumeration<K> e=t.keys(); e.hasMoreElements();)
		{
			keys.add(e.nextElement());
		}
		
		Collections.sort(keys,c);
		
		return keys;
	}
}
